<template>
  <div class="container">
    <van-tabs v-model="active">
      <van-tab title="视频学习">
        <record-list id="f3dca92a7c4842d8b2854cab8b28d884" type="1"></record-list>
      </van-tab>
      <van-tab title="文件学习">
        <record-list id="47e64d807cd84fa5bcd9d4a0cc9ac16e" type="0"></record-list>
      </van-tab>
    </van-tabs>
  </div>
</template>
<script>
import recordList from '@/components/record-list'

export default {
  components: {
    recordList
  },
  data () {
    return {
      active: 0,
      type: 'video'
    }
  },
  created () {
    const { type } = this.$route.params
    if (type === 'file') {
      this.active = 1
    }
  },
  methods: {}
}
</script>
<style lang="less" scoped>
.van-tabs {
  /deep/ .van-tabs__nav {
    .van-tab--active {
      color: #f0321d;
    }
    .van-tabs__line {
      height: 2px;
      background-color: #f0321d;
    }
  }
}
</style>
